package com.yamaikeji.system.domain.plan;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.yamaikeji.common.core.domain.BaseEntity;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;

import java.time.LocalDate;
import java.time.LocalDateTime;
import java.util.List;

/**
 * 任务对象 p_task
 * 
 * @author yamaikeji
 * @date 2023-10-03
 */
public class Task extends BaseEntity {

    private static final long serialVersionUID = 1L;

    /** id */
    private Long id;

    /** 任务编号 */
    private String taskNo;

    /** 计划编号 */
    private String planNo;

    /** 用户编号 */
    private String userNo;

    /** 任务时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    private LocalDate taskTime;

    /** 任务状态(0未完成 1已完成 2已取消) */
    private String taskStatus;

    /** 完成时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    private LocalDateTime completeTime;

    /** 删除标志（0存在 2删除） */
    private String delFlag;

    // 拓展字段
    /** 任务总数  */
    private Integer totalTaskNum;

    /** 已完成任务数 */
    private Integer completeTaskNum;

    /** 未完成任务数 */
    private Integer notCompleteTaskNum;

    /** 取消任务数 */
    private Integer cancelTaskNum;

    /** 任务完成率  */
    private Integer taskCompleteRate;

    /** 计划类型*/
    private String planTypeNo;

    /** 计划名称 */
    private String planName;

    /** 提醒开关（0开启 1关闭） */
    private String tipSwitch;

    /** 提醒时间 */
    private String tipTime;

    /** 计划备注 */
    private String planRemark;

    /** 当前时间 */
    private LocalDate nowTime;

    private List<LocalDate> taskTimeList;

    /** 开始时间 */
    private LocalDate beginTime;

    /** 结束时间 */
    private LocalDate endTime;

    /** 周期等级 */
    private String planLevel;

    /** 已用时长 单位秒 */
    private Long useTime;

    /** 计划类型名称 */
    private String planTypeName;

    /** 图标类型 1icon 2symbol 3图片 */
    private String imageType;

    /** 图标 */
    private String image;

    /** 颜色 */
    private String color;

    private List<PlanTask> planTaskList;

    /** 计划编号列表 */
    private List<String> planNoList;

    /** 已用时长 单位秒 */
    private Long planUseTime;

    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public String getTaskNo() {
        return taskNo;
    }

    public void setTaskNo(String taskNo) {
        this.taskNo = taskNo;
    }

    public String getPlanNo() {
        return planNo;
    }

    public void setPlanNo(String planNo) {
        this.planNo = planNo;
    }

    public String getUserNo() {
        return userNo;
    }

    public void setUserNo(String userNo) {
        this.userNo = userNo;
    }

    public LocalDate getTaskTime() {
        return taskTime;
    }

    public void setTaskTime(LocalDate taskTime) {
        this.taskTime = taskTime;
    }

    public String getTaskStatus() {
        return taskStatus;
    }

    public void setTaskStatus(String taskStatus) {
        this.taskStatus = taskStatus;
    }

    public LocalDateTime getCompleteTime() {
        return completeTime;
    }

    public void setCompleteTime(LocalDateTime completeTime) {
        this.completeTime = completeTime;
    }

    public String getDelFlag() {
        return delFlag;
    }

    public void setDelFlag(String delFlag) {
        this.delFlag = delFlag;
    }

    public Integer getTotalTaskNum() {
        return totalTaskNum;
    }

    public void setTotalTaskNum(Integer totalTaskNum) {
        this.totalTaskNum = totalTaskNum;
    }

    public Integer getCompleteTaskNum() {
        return completeTaskNum;
    }

    public void setCompleteTaskNum(Integer completeTaskNum) {
        this.completeTaskNum = completeTaskNum;
    }

    public Integer getNotCompleteTaskNum() {
        return notCompleteTaskNum;
    }

    public void setNotCompleteTaskNum(Integer notCompleteTaskNum) {
        this.notCompleteTaskNum = notCompleteTaskNum;
    }

    public Integer getCancelTaskNum() {
        return cancelTaskNum;
    }

    public void setCancelTaskNum(Integer cancelTaskNum) {
        this.cancelTaskNum = cancelTaskNum;
    }

    public Integer getTaskCompleteRate() {
        return taskCompleteRate;
    }

    public void setTaskCompleteRate(Integer taskCompleteRate) {
        this.taskCompleteRate = taskCompleteRate;
    }

    public String getPlanTypeNo() {
        return planTypeNo;
    }

    public void setPlanTypeNo(String planTypeNo) {
        this.planTypeNo = planTypeNo;
    }

    public String getPlanName() {
        return planName;
    }

    public void setPlanName(String planName) {
        this.planName = planName;
    }

    public String getTipSwitch() {
        return tipSwitch;
    }

    public void setTipSwitch(String tipSwitch) {
        this.tipSwitch = tipSwitch;
    }

    public String getTipTime() {
        return tipTime;
    }

    public void setTipTime(String tipTime) {
        this.tipTime = tipTime;
    }

    public String getPlanRemark() {
        return planRemark;
    }

    public void setPlanRemark(String planRemark) {
        this.planRemark = planRemark;
    }

    public LocalDate getNowTime() {
        return nowTime;
    }

    public void setNowTime(LocalDate nowTime) {
        this.nowTime = nowTime;
    }

    public List<LocalDate> getTaskTimeList() {
        return taskTimeList;
    }

    public void setTaskTimeList(List<LocalDate> taskTimeList) {
        this.taskTimeList = taskTimeList;
    }

    public LocalDate getBeginTime() {
        return beginTime;
    }

    public void setBeginTime(LocalDate beginTime) {
        this.beginTime = beginTime;
    }

    public LocalDate getEndTime() {
        return endTime;
    }

    public void setEndTime(LocalDate endTime) {
        this.endTime = endTime;
    }

    public Long getUseTime() {
        return useTime;
    }

    public void setUseTime(Long useTime) {
        this.useTime = useTime;
    }

    public String getPlanLevel() {
        return planLevel;
    }

    public void setPlanLevel(String planLevel) {
        this.planLevel = planLevel;
    }

    public String getPlanTypeName() {
        return planTypeName;
    }

    public void setPlanTypeName(String planTypeName) {
        this.planTypeName = planTypeName;
    }

    public String getImageType() {
        return imageType;
    }

    public void setImageType(String imageType) {
        this.imageType = imageType;
    }

    public String getImage() {
        return image;
    }

    public void setImage(String image) {
        this.image = image;
    }

    public String getColor() {
        return color;
    }

    public void setColor(String color) {
        this.color = color;
    }

    public List<PlanTask> getPlanTaskList() {
        return planTaskList;
    }

    public void setPlanTaskList(List<PlanTask> planTaskList) {
        this.planTaskList = planTaskList;
    }

    public List<String> getPlanNoList() {
        return planNoList;
    }

    public void setPlanNoList(List<String> planNoList) {
        this.planNoList = planNoList;
    }

    public Long getPlanUseTime() {
        return planUseTime;
    }

    public void setPlanUseTime(Long planUseTime) {
        this.planUseTime = planUseTime;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
            .append("id", getId())
            .append("taskNo", getTaskNo())
            .append("planNo", getPlanNo())
            .append("userNo", getUserNo())
            .append("taskTime", getTaskTime())
            .append("taskStatus", getTaskStatus())
            .append("completeTime", getTaskStatus())
            .append("delFlag", getDelFlag())
            .append("createBy", getCreateBy())
            .append("createTime", getCreateTime())
            .append("updateBy", getUpdateBy())
            .append("updateTime", getUpdateTime())
            .toString();
    }
}
